{smcl}
{com}{sf}{ul off}{txt}{.-}
      name:  {res}<unnamed>
       {txt}log:  {res}/Users/fcoell/Dropbox/PATSTAT/DATA/../logs/Appendix_Section_K.smcl
  {txt}log type:  {res}smcl
 {txt}opened on:  {res}14 Apr 2020, 11:55:19
{txt}
{com}. di "******************* Section K, Appendix, desctiptives *******************"
{res}******************* Section K, Appendix, desctiptives *******************
{txt}
{com}. 
. // Find top 10 countries by GDP in 2000 (Source, IMF WEO)
. import excel Ctry_heterog_data/imf_GDP_20191209.xls, sheet("NGDPD") firstrow clear
{res}{text}(46 vars, 229 obs)

{com}. rename (GDPcurrentpricesBillionsof N V) (country gdp1992 gdp2000)
{res}{txt}
{com}. keep country gdp1992 gdp2000
{txt}
{com}. destring gdp1992, replace ignore("no data")
{txt}gdp1992: characters{res} n o space d a t{txt} removed; {res}replaced {txt}as {res}double
{txt}(27 missing values generated)
{res}{txt}
{com}. destring gdp2000, replace ignore("no data")
{txt}gdp2000: characters{res} n o space d a t{txt} removed; {res}replaced {txt}as {res}double
{txt}(9 missing values generated)
{res}{txt}
{com}. gsort - gdp2000
{txt}
{com}. list
{txt}
     {c TLC}{hline 42}{c -}{hline 11}{c -}{hline 11}{c TRC}
     {c |} {res}                                 country     gdp1992     gdp2000 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
  1. {c |} {res}                                   World   25197.763   33858.446 {txt}{c |}
  2. {c |} {res}                      Advanced economies   21071.993   26787.507 {txt}{c |}
  3. {c |} {res}           Major advanced economies (G7)   17161.228   21996.078 {txt}{c |}
  4. {c |} {res}             Western Hemisphere (Region)    8508.433   13267.587 {txt}{c |}
  5. {c |} {res}                           North America    7553.053   11766.584 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
  6. {c |} {res}                           United States    6520.325    10252.35 {txt}{c |}
  7. {c |} {res}                                  Europe    9138.086    9719.545 {txt}{c |}
  8. {c |} {res}                        Asia and Pacific    6580.793    9245.485 {txt}{c |}
  9. {c |} {res}                          Western Europe    8819.157    8952.575 {txt}{c |}
 10. {c |} {res}                          European Union    8597.919    8918.864 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 11. {c |} {res}                               East Asia    5095.381    7182.994 {txt}{c |}
 12. {c |} {res}Emerging market and developing economies     4125.77    7070.939 {txt}{c |}
 13. {c |} {res}                               Euro area    6720.446    6489.281 {txt}{c |}
 14. {c |} {res}                                   Japan    3908.808     4887.52 {txt}{c |}
 15. {c |} {res}                Other advanced economies    2051.388    2762.084 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 16. {c |} {res}            Emerging and Developing Asia    1278.275    2324.387 {txt}{c |}
 17. {c |} {res}         Latin America and the Caribbean    1359.112    2208.912 {txt}{c |}
 18. {c |} {res}                                 Germany    2136.312    1948.843 {txt}{c |}
 19. {c |} {res}                          United Kingdom    1284.454    1651.392 {txt}{c |}
 20. {c |} {res}                           South America     883.893    1369.544 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 21. {c |} {res}                                  France    1404.391    1366.243 {txt}{c |}
 22. {c |} {res}            Middle East and Central Asia     584.092     1230.01 {txt}{c |}
 23. {c |} {res}             China, People's Republic of     495.671    1214.915 {txt}{c |}
 24. {c |} {res}                                   Italy    1312.572    1145.108 {txt}{c |}
 25. {c |} {res}                    Middle East (Region)     399.549     956.513 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 26. {c |} {res}          Emerging and Developing Europe     517.056     914.223 {txt}{c |}
 27. {c |} {res}                         Eastern Europe       318.93      766.97 {txt}{c |}
 28. {c |} {res}                                  Canada     594.365     744.623 {txt}{c |}
 29. {c |} {res}                                  Mexico     403.733     707.909 {txt}{c |}
 30. {c |} {res}                         Africa (Region)     570.902     666.719 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 31. {c |} {res}                                  Brazil     382.329     655.435 {txt}{c |}
 32. {c |} {res}                          Southeast Asia     478.412      637.86 {txt}{c |}
 33. {c |} {res}                              South Asia     409.057     637.266 {txt}{c |}
 34. {c |} {res}                                   Spain     628.565     597.148 {txt}{c |}
 35. {c |} {res}                      Korea, Republic of     361.676     576.179 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 36. {c |} {res}                                 ASEAN-5     416.842     520.222 {txt}{c |}
 37. {c |} {res}                                   India     293.262     476.636 {txt}{c |}
 38. {c |} {res}               Australia and New Zealand     358.994     453.265 {txt}{c |}
 39. {c |} {res}                             Netherlands     365.971     417.664 {txt}{c |}
 40. {c |} {res}            Sub-Saharan Africa (Region)       392.47     408.615 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 41. {c |} {res}                               Australia     317.469     399.126 {txt}{c |}
 42. {c |} {res}                      Sub-Saharan Africa     387.234     393.407 {txt}{c |}
 43. {c |} {res}                                    Iran      49.423     365.946 {txt}{c |}
 44. {c |} {res}                Taiwan Province of China     223.123     331.407 {txt}{c |}
 45. {c |} {res}           Central Asia and the Caucasus     229.787     325.807 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 46. {c |} {res}                               Argentina     247.987     308.491 {txt}{c |}
 47. {c |} {res}                      Russian Federation       91.76     278.496 {txt}{c |}
 48. {c |} {res}                                  Turkey     219.091     273.085 {txt}{c |}
 49. {c |} {res}                             Switzerland     271.577     272.179 {txt}{c |}
 50. {c |} {res}                                  Sweden     280.572     261.336 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 51. {c |} {res}                            North Africa     178.432     258.104 {txt}{c |}
 52. {c |} {res}                                 Belgium     229.957     238.602 {txt}{c |}
 53. {c |} {res}                                 Austria     195.506     197.377 {txt}{c |}
 54. {c |} {res}                            Saudi Arabia     136.905     189.515 {txt}{c |}
 55. {c |} {res}                               Indonesia      168.28     179.482 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 56. {c |} {res}                           Hong Kong SAR     104.272     171.643 {txt}{c |}
 57. {c |} {res}                                  Poland      88.713     171.276 {txt}{c |}
 58. {c |} {res}                                  Norway     130.838     171.246 {txt}{c |}
 59. {c |} {res}                                 Denmark     152.915     164.158 {txt}{c |}
 60. {c |} {res}                            South Africa     134.557     136.453 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 61. {c |} {res}                                  Israel      73.547     132.243 {txt}{c |}
 62. {c |} {res}                                  Greece     116.466     132.198 {txt}{c |}
 63. {c |} {res}                                Thailand     115.576     126.392 {txt}{c |}
 64. {c |} {res}                                 Finland     113.227     125.908 {txt}{c |}
 65. {c |} {res}                                Portugal     108.119     118.658 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 66. {c |} {res}                               Venezuela        60.4     117.676 {txt}{c |}
 67. {c |} {res}                                   Egypt      44.168     104.752 {txt}{c |}
 68. {c |} {res}                    United Arab Emirates      52.208     103.893 {txt}{c |}
 69. {c |} {res}                                Malaysia      64.424     102.149 {txt}{c |}
 70. {c |} {res}                                 Ireland      54.892     100.139 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 71. {c |} {res}                                Colombia      68.345      98.931 {txt}{c |}
 72. {c |} {res}                               Singapore      52.131      96.077 {txt}{c |}
 73. {c |} {res}                             Philippines      58.695      81.023 {txt}{c |}
 74. {c |} {res}                                Pakistan      63.727      79.705 {txt}{c |}
 75. {c |} {res}                                   Chile       46.27      77.815 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 76. {c |} {res}                         Central America      40.257      69.484 {txt}{c |}
 77. {c |} {res}                                 Nigeria      52.275      67.824 {txt}{c |}
 78. {c |} {res}                               Caribbean      31.229      61.974 {txt}{c |}
 79. {c |} {res}                             Puerto Rico       34.63      61.702 {txt}{c |}
 80. {c |} {res}                          Czech Republic           .      61.645 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 81. {c |} {res}                                 Algeria      49.217      54.749 {txt}{c |}
 82. {c |} {res}                              Bangladesh      36.476      54.586 {txt}{c |}
 83. {c |} {res}                             New Zealand      41.525      54.139 {txt}{c |}
 84. {c |} {res}                                    Peru      35.377      50.414 {txt}{c |}
 85. {c |} {res}                                 Hungary      38.725      47.311 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 86. {c |} {res}                                 Morocco      33.712      38.859 {txt}{c |}
 87. {c |} {res}                                   Libya      34.358      38.271 {txt}{c |}
 88. {c |} {res}                                  Kuwait      19.866      37.721 {txt}{c |}
 89. {c |} {res}                                 Romania      19.779      37.281 {txt}{c |}
 90. {c |} {res}                                 Ukraine      22.193      32.331 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 91. {c |} {res}                                 Vietnam       9.867      31.176 {txt}{c |}
 92. {c |} {res}                                    Iraq           .      25.857 {txt}{c |}
 93. {c |} {res}                      Dominican Republic      11.605      24.306 {txt}{c |}
 94. {c |} {res}                                 Uruguay      14.223      22.832 {txt}{c |}
 95. {c |} {res}                                 Croatia      12.247      21.774 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
 96. {c |} {res}                                 Tunisia      16.978      21.474 {txt}{c |}
 97. {c |} {res}                              Luxembourg       15.39      21.326 {txt}{c |}
 98. {c |} {res}                         Slovak Republic           .      20.691 {txt}{c |}
 99. {c |} {res}                                Slovenia      19.271      20.393 {txt}{c |}
100. {c |} {res}                                   Syria      13.263      19.861 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
101. {c |} {res}                                    Oman      12.452      19.507 {txt}{c |}
102. {c |} {res}                               Sri Lanka      11.176      19.371 {txt}{c |}
103. {c |} {res}                 Congo, Dem. Rep. of the      36.333      19.077 {txt}{c |}
104. {c |} {res}                                 Ecuador      15.012      18.319 {txt}{c |}
105. {c |} {res}                              Kazakhstan       2.875      18.292 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
106. {c |} {res}                                   Qatar       7.646       17.76 {txt}{c |}
107. {c |} {res}                               Guatemala       9.625      17.187 {txt}{c |}
108. {c |} {res}                                 Lebanon       5.468      17.007 {txt}{c |}
109. {c |} {res}                              Uzbekistan       4.361      16.808 {txt}{c |}
110. {c |} {res}                              Costa Rica       8.578      14.965 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
111. {c |} {res}                                   Kenya      11.327      14.136 {txt}{c |}
112. {c |} {res}                                Bulgaria       7.861      13.153 {txt}{c |}
113. {c |} {res}                                   Sudan         3.1      13.134 {txt}{c |}
114. {c |} {res}                                 Belarus      12.364      12.758 {txt}{c |}
115. {c |} {res}                                  Panama       7.153      12.502 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
116. {c |} {res}                                Tanzania       5.588      12.369 {txt}{c |}
117. {c |} {res}                             El Salvador       5.813      11.785 {txt}{c |}
118. {c |} {res}                               Lithuania           .      11.539 {txt}{c |}
119. {c |} {res}                                   Ghana      16.484      11.467 {txt}{c |}
120. {c |} {res}                                Zimbabwe       7.793       11.34 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
121. {c |} {res}                                  Angola       9.395      11.166 {txt}{c |}
122. {c |} {res}                           Côte d'Ivoire      11.153      10.717 {txt}{c |}
123. {c |} {res}                                  Cyprus       7.424       9.988 {txt}{c |}
124. {c |} {res}                                Cameroon      13.851       9.802 {txt}{c |}
125. {c |} {res}                                   Yemen      17.959       9.679 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
126. {c |} {res}                                  Serbia           .       9.312 {txt}{c |}
127. {c |} {res}                                 Myanmar           .       9.073 {txt}{c |}
128. {c |} {res}                                 Jamaica       4.328       9.065 {txt}{c |}
129. {c |} {res}                                 Bahrain       5.442       9.063 {txt}{c |}
130. {c |} {res}                                 Iceland       7.112       9.004 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
131. {c |} {res}                                Paraguay       7.158       8.856 {txt}{c |}
132. {c |} {res}                                  Jordan       5.369       8.461 {txt}{c |}
133. {c |} {res}                                 Bolivia       5.643       8.385 {txt}{c |}
134. {c |} {res}                     Trinidad and Tobago       5.533       8.295 {txt}{c |}
135. {c |} {res}                        Pacific Islands        9.162       8.293 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
136. {c |} {res}                                Ethiopia      14.696       8.235 {txt}{c |}
137. {c |} {res}                            Bahamas, The       5.125       8.076 {txt}{c |}
138. {c |} {res}                                  Latvia       1.694       7.941 {txt}{c |}
139. {c |} {res}                                Honduras       4.675       7.104 {txt}{c |}
140. {c |} {res}                       Brunei Darussalam       4.646       6.662 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
141. {c |} {res}                                  Uganda       2.809       5.978 {txt}{c |}
142. {c |} {res}                                 Senegal       7.602       5.966 {txt}{c |}
143. {c |} {res}                                Botswana       3.932       5.803 {txt}{c |}
144. {c |} {res}                                   Nepal       3.872       5.731 {txt}{c |}
145. {c |} {res}                                 Estonia           .       5.714 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
146. {c |} {res}                  Bosnia and Herzegovina           .       5.554 {txt}{c |}
147. {c |} {res}                                   Gabon       5.955       5.397 {txt}{c |}
148. {c |} {res}                        Papua New Guinea       6.617       5.289 {txt}{c |}
149. {c |} {res}                              Azerbaijan       1.193       5.273 {txt}{c |}
150. {c |} {res}                               Nicaragua       3.894       5.109 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
151. {c |} {res}                            Turkmenistan        .951       5.022 {txt}{c |}
152. {c |} {res}                               Mauritius       3.352       4.869 {txt}{c |}
153. {c |} {res}                              Mozambique       2.238       4.667 {txt}{c |}
154. {c |} {res}                                   Malta       2.895       4.059 {txt}{c |}
155. {c |} {res}                                  Guinea        4.57       4.039 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
156. {c |} {res}                                   Haiti        .533       3.952 {txt}{c |}
157. {c |} {res}                                 Namibia       3.014       3.911 {txt}{c |}
158. {c |} {res}                              Madagascar       3.001       3.878 {txt}{c |}
159. {c |} {res}                        North Macedonia        2.443       3.774 {txt}{c |}
160. {c |} {res}                                Cambodia       2.439       3.667 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
161. {c |} {res}                                  Zambia       3.614       3.601 {txt}{c |}
162. {c |} {res}                                   Benin       3.284       3.522 {txt}{c |}
163. {c |} {res}                                 Albania        .843       3.483 {txt}{c |}
164. {c |} {res}                     Congo, Republic of        2.933        3.22 {txt}{c |}
165. {c |} {res}                                Barbados       1.957       3.059 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
166. {c |} {res}                                 Georgia           .       3.057 {txt}{c |}
167. {c |} {res}                                  Malawi        3.12       3.023 {txt}{c |}
168. {c |} {res}                                    Mali       3.372       2.963 {txt}{c |}
169. {c |} {res}                            Burkina Faso       3.357       2.633 {txt}{c |}
170. {c |} {res}                                  Kosovo           .       2.092 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
171. {c |} {res}                                 Armenia        .108       1.912 {txt}{c |}
172. {c |} {res}                                   Aruba           .       1.873 {txt}{c |}
173. {c |} {res}                                    Fiji       1.659       1.824 {txt}{c |}
174. {c |} {res}                                Eswatini       1.425       1.739 {txt}{c |}
175. {c |} {res}                              Lao P.D.R.       2.354        1.72 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
176. {c |} {res}                                  Rwanda        1.95       1.718 {txt}{c |}
177. {c |} {res}                                   Niger       2.345       1.671 {txt}{c |}
178. {c |} {res}                                 Moldova       1.036       1.578 {txt}{c |}
179. {c |} {res}                                    Chad       1.886       1.572 {txt}{c |}
180. {c |} {res}                                    Togo        2.13       1.493 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
181. {c |} {res}                         Kyrgyz Republic        .917       1.368 {txt}{c |}
182. {c |} {res}                                Mongolia       1.831       1.329 {txt}{c |}
183. {c |} {res}                              Mauritania       1.464       1.294 {txt}{c |}
184. {c |} {res}                                Suriname        .551       1.266 {txt}{c |}
185. {c |} {res}                       Equatorial Guinea         .16       1.156 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
186. {c |} {res}                                  Guyana        .598       1.124 {txt}{c |}
187. {c |} {res}                             Gambia, The         .82        1.01 {txt}{c |}
188. {c |} {res}                              Tajikistan        .291        .991 {txt}{c |}
189. {c |} {res}                              Montenegro           .        .966 {txt}{c |}
190. {c |} {res}                            Sierra Leone        .992        .941 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
191. {c |} {res}                                 Lesotho        .877        .911 {txt}{c |}
192. {c |} {res}                                 Liberia           .        .874 {txt}{c |}
193. {c |} {res}                                 Burundi       1.082         .87 {txt}{c |}
194. {c |} {res}                Central African Republic       1.494        .868 {txt}{c |}
195. {c |} {res}                             Saint Lucia        .603        .834 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
196. {c |} {res}                                  Belize        .518        .832 {txt}{c |}
197. {c |} {res}                     Antigua and Barbuda        .499         .83 {txt}{c |}
198. {c |} {res}                                Maldives        .306        .801 {txt}{c |}
199. {c |} {res}                                Djibouti        .671         .78 {txt}{c |}
200. {c |} {res}                              Seychelles        .434        .615 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
201. {c |} {res}                              Cabo Verde        .395        .589 {txt}{c |}
202. {c |} {res}                                 Eritrea        .606        .547 {txt}{c |}
203. {c |} {res}                                 Grenada         .31         .52 {txt}{c |}
204. {c |} {res}                             Timor-Leste           .         .44 {txt}{c |}
205. {c |} {res}                                  Bhutan        .238        .436 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
206. {c |} {res}                   Saint Kitts and Nevis        .223        .433 {txt}{c |}
207. {c |} {res}        Saint Vincent and the Grenadines        .278        .396 {txt}{c |}
208. {c |} {res}                         Solomon Islands        .261        .381 {txt}{c |}
209. {c |} {res}                           Guinea-Bissau          .5        .364 {txt}{c |}
210. {c |} {res}                                 Comoros        .436        .339 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
211. {c |} {res}                                Dominica        .234        .333 {txt}{c |}
212. {c |} {res}                                 Vanuatu        .209        .272 {txt}{c |}
213. {c |} {res}                                   Samoa        .188        .264 {txt}{c |}
214. {c |} {res}              Micronesia, Fed. States of           .        .233 {txt}{c |}
215. {c |} {res}                                   Tonga         .18        .195 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
216. {c |} {res}                                   Palau           .        .146 {txt}{c |}
217. {c |} {res}                        Marshall Islands           .        .112 {txt}{c |}
218. {c |} {res}                   São Tomé and Príncipe        .096        .077 {txt}{c |}
219. {c |} {res}                                Kiribati        .048        .068 {txt}{c |}
220. {c |} {res}                                  Tuvalu           .        .014 {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
221. {c |} {res}                                                   .           . {txt}{c |}
222. {c |} {res}                              ©IMF, 2019           .           . {txt}{c |}
223. {c |} {res}                                                   .           . {txt}{c |}
224. {c |} {res}                                   Nauru           .           . {txt}{c |}
225. {c |} {res}                                 Somalia           .           . {txt}{c |}
     {c LT}{hline 42}{c -}{hline 11}{c -}{hline 11}{c RT}
226. {c |} {res}                South Sudan, Republic of           .           . {txt}{c |}
227. {c |} {res}                               Macao SAR           .           . {txt}{c |}
228. {c |} {res}                             Afghanistan           .           . {txt}{c |}
229. {c |} {res}                              San Marino           .           . {txt}{c |}
     {c BLC}{hline 42}{c -}{hline 11}{c -}{hline 11}{c BRC}

{com}. 
. // Get all patents for each firm and year (from firm_patents2.do)
. use patents_docdb, clear
{txt}
{com}. drop mkts inEP inUS inJP
{txt}
{com}. label var granted "Granted patent"
{txt}
{com}. label var citations "Number of citations for the patent"
{txt}
{com}. label var citations3year "Number of citations after 3 years for the patent"
{txt}
{com}. label var num_inventors "Number of inventors for the patent"
{txt}
{com}. label var num_ipc "Number of IPC codes for patent"
{txt}
{com}. label var num_cpc "Number of CPC codes for patent"
{txt}
{com}. save $tmp/patents_docdb, replace
{txt}file /tmp/patents_docdb.dta saved

{com}. 
. // Save a temporary final sample with patents
. use $tmp/patents_docdb, clear
{txt}
{com}. merge m:1 hrm_l2_id using $tmp/final_sample, assert(match master)
{res}
{txt}{col 5}Result{col 38}# of obs.
{col 5}{hline 41}
{col 5}not matched{col 30}{res}      38,853,646
{txt}{col 9}from master{col 30}{res}      38,853,646{txt}  (_merge==1)
{col 9}from using{col 30}{res}               0{txt}  (_merge==2)

{col 5}matched{col 30}{res}       4,001,039{txt}  (_merge==3)
{col 5}{hline 41}

{com}. keep if _merge == 3
{txt}(38,853,646 observations deleted)

{com}. drop _merge
{txt}
{com}. save $tmp/finsample, replace
{txt}file /tmp/finsample.dta saved

{com}. 
. // Save a temporary initial sample with patents
. use $tmp/patents_docdb, clear
{txt}
{com}. merge m:1 hrm_l2_id using $tmp/initial_sample, assert(match master)
{res}
{txt}{col 5}Result{col 38}# of obs.
{col 5}{hline 41}
{col 5}not matched{col 30}{res}      22,293,460
{txt}{col 9}from master{col 30}{res}      22,293,460{txt}  (_merge==1)
{col 9}from using{col 30}{res}               0{txt}  (_merge==2)

{col 5}matched{col 30}{res}      20,561,225{txt}  (_merge==3)
{col 5}{hline 41}

{com}. keep if _merge == 3
{txt}(22,293,460 observations deleted)

{com}. drop _merge
{txt}
{com}. save $tmp/initsample, replace
{txt}file /tmp/initsample.dta saved

{com}. 
. 
. *------------------------------------------------------------------------------
. * Appendix Table 8 - Final sample
. * Patents quality descriptives
. *------------------------------------------------------------------------------
. // TOTALS: Patents, granted patents, citations, inventors and patent breadh
. // If a patent is co-owned, we count it only once
. use $tmp/finsample, clear
{txt}
{com}. collapse (max) granted (mean) citations3year num_inventors num_ipc num_cpc ///
>         (min) y, by(docdb_family_id)
{txt}
{com}. keep if y>=1992 & y<=2000 // sample period
{txt}(2,697,657 observations deleted)

{com}. preserve
{txt}
{com}. collapse (count) totp = docdb_family_id (sum) totg = granted
{txt}
{com}. gen sh_granted = totg/totp // Share of granted patents
{txt}
{com}. tabstat totp totg sh_granted

{txt}   stats {...}
{c |}{...}
      totp      totg  sh_gra~d
{hline 9}{c +}{hline 30}
{ralign 8:mean} {...}
{c |}{...}
 {res}  1133082    634332  .5598289
{txt}{hline 9}{c BT}{hline 30}

{com}. restore
{txt}
{com}. // Quality descriptives based on granted patents only
. keep if granted == 1
{txt}(498,750 observations deleted)

{com}. collapse (sum) totg = granted (mean) citations3year num_inventors num_ipc num_cpc
{txt}
{com}. tabstat totg citations3year num_inventors num_ipc num_cpc

{txt}   stats {...}
{c |}{...}
      totg  citati~r  num_in~s   num_ipc   num_cpc
{hline 9}{c +}{hline 50}
{ralign 8:mean} {...}
{c |}{...}
 {res}   634332  3.280115  2.194878  3.195412   4.03542
{txt}{hline 9}{c BT}{hline 50}

{com}. 
. // BY COUNTRY: Patents, granted patents, citations, inventors and patent breadh
. // If a patent is co-owned by firms in different countries, we count it once
. // for each countryuse $tmp/finsample, clear
. use $tmp/finsample, clear
{txt}
{com}. gen top10 = (headq=="US" | headq=="JP" | headq=="DE" | headq=="GB" | headq=="FR" ///
>         | headq=="IT" | headq=="CA" | headq=="MX" | headq=="BR" | headq=="ES") 
{txt}
{com}.         // 10 major economies in 2000 (nominal gdp)
. collapse (max) granted (mean) citations3year num_inventors num_ipc num_cpc ///
>         (min) y, by(docdb_family_id headq top10)
{txt}
{com}. keep if y>=1992 & y<=2000 // sample period
{txt}(2,714,011 observations deleted)

{com}. preserve
{txt}
{com}. collapse (count) totp=docdb_family_id (sum) totg=granted, by(headq top10)
{txt}
{com}. gen sh_granted = totg/totp // Share of granted patents
{txt}
{com}. tabstat totp totg sh_granted if top10 == 1, by(headq) nototal

{txt}Summary statistics: mean
  by categories of: headq 

{ralign 5:headq} {...}
{c |}{...}
      totp      totg  sh_gra~d
{hline 6}{c +}{hline 30}
{ralign 5:BR} {...}
{c |}{...}
 {res}      725       199  .2744828
{txt}{ralign 5:CA} {...}
{c |}{...}
 {res}    11256      8296  .7370291
{txt}{ralign 5:DE} {...}
{c |}{...}
 {res}    51085     32439  .6350005
{txt}{ralign 5:ES} {...}
{c |}{...}
 {res}     2654      2330  .8779201
{txt}{ralign 5:FR} {...}
{c |}{...}
 {res}    26023     21085  .8102448
{txt}{ralign 5:GB} {...}
{c |}{...}
 {res}    21021      9862  .4691499
{txt}{ralign 5:IT} {...}
{c |}{...}
 {res}    18556     15580  .8396206
{txt}{ralign 5:JP} {...}
{c |}{...}
 {res}   630263    250979  .3982131
{txt}{ralign 5:MX} {...}
{c |}{...}
 {res}      148        57  .3851351
{txt}{ralign 5:US} {...}
{c |}{...}
 {res}   169484    140211  .8272817
{txt}{hline 6}{c BT}{hline 30}

{com}. restore
{txt}
{com}. // Quality descriptives based on granted patents only
. keep if granted == 1
{txt}(503,625 observations deleted)

{com}. collapse (sum) totg = granted (mean) citations3year num_inventors num_ipc ///
>         num_cpc, by(headq top10)
{txt}
{com}. tabstat totg citations3year num_inventors num_ipc num_cpc if top10 == 1, by(headq) nototal

{txt}Summary statistics: mean
  by categories of: headq 

{ralign 5:headq} {...}
{c |}{...}
      totg  citati~r  num_in~s   num_ipc   num_cpc
{hline 6}{c +}{hline 50}
{ralign 5:BR} {...}
{c |}{...}
 {res}      199  1.136516  2.107521  2.645939   3.09434
{txt}{ralign 5:CA} {...}
{c |}{...}
 {res}     8296  8.950358  2.413229   3.50804  4.364062
{txt}{ralign 5:DE} {...}
{c |}{...}
 {res}    32439  2.504263  2.231044  3.507775  3.592139
{txt}{ralign 5:ES} {...}
{c |}{...}
 {res}     2330  .8239485  2.037141  2.360874  3.013963
{txt}{ralign 5:FR} {...}
{c |}{...}
 {res}    21085  2.151854  2.057464  3.602621  3.567032
{txt}{ralign 5:GB} {...}
{c |}{...}
 {res}     9862  3.332022  2.036932  4.105469  4.283667
{txt}{ralign 5:IT} {...}
{c |}{...}
 {res}    15580  2.323712  1.909862  2.616713  3.274114
{txt}{ralign 5:JP} {...}
{c |}{...}
 {res}   250979   1.85305  2.451511  3.467243  3.894977
{txt}{ralign 5:MX} {...}
{c |}{...}
 {res}       57  2.359649  2.316667  2.087573      3.42
{txt}{ralign 5:US} {...}
{c |}{...}
 {res}   140211  8.162482  2.326819  3.754447  4.452637
{txt}{hline 6}{c BT}{hline 50}

{com}. 
. 
. * -----------------------------------------------------------------------------
. * Appendix Table 9 - Final sample
. * Patenting by industry (and country)
. * -----------------------------------------------------------------------------
. // Total number of patents in the world 1992-2000 by industry
. // Drop duplicates in nace (2 digit)
. // Note: a patent is only counted once in each nace (2 digit)
. use $tmp/finsample, clear
{txt}
{com}. gen nace = int(nace2_1) // 2-digit nace
{txt}
{com}. collapse (max) granted (min) y, by(docdb_family_id nace)
{txt}
{com}. keep if y>=1992 & y<=2000 // sample period
{txt}(2,745,995 observations deleted)

{com}. collapse (count) p = docdb (sum) granted, by(nace)
{txt}
{com}. tabstat p granted, by(nace) nototal

{txt}Summary statistics: mean
  by categories of: nace 

{ralign 8:nace} {...}
{c |}{...}
         p   granted
{hline 9}{c +}{hline 20}
{ralign 8:10} {...}
{c |}{...}
 {res}     9949      6014
{txt}{ralign 8:11} {...}
{c |}{...}
 {res}      657       410
{txt}{ralign 8:12} {...}
{c |}{...}
 {res}      394       249
{txt}{ralign 8:13} {...}
{c |}{...}
 {res}     3637      2176
{txt}{ralign 8:14} {...}
{c |}{...}
 {res}      773       491
{txt}{ralign 8:15} {...}
{c |}{...}
 {res}     1407       948
{txt}{ralign 8:16} {...}
{c |}{...}
 {res}      310       143
{txt}{ralign 8:17} {...}
{c |}{...}
 {res}     4269      1513
{txt}{ralign 8:18} {...}
{c |}{...}
 {res}     1835       854
{txt}{ralign 8:19} {...}
{c |}{...}
 {res}     1086       684
{txt}{ralign 8:20} {...}
{c |}{...}
 {res}   124370     57814
{txt}{ralign 8:21} {...}
{c |}{...}
 {res}    51552     31900
{txt}{ralign 8:22} {...}
{c |}{...}
 {res}    39167     19186
{txt}{ralign 8:23} {...}
{c |}{...}
 {res}    30225     11866
{txt}{ralign 8:24} {...}
{c |}{...}
 {res}    21443     13451
{txt}{ralign 8:25} {...}
{c |}{...}
 {res}    17560     11287
{txt}{ralign 8:26} {...}
{c |}{...}
 {res}   324765    202341
{txt}{ralign 8:27} {...}
{c |}{...}
 {res}    72899     34065
{txt}{ralign 8:28} {...}
{c |}{...}
 {res}   275090    143605
{txt}{ralign 8:29} {...}
{c |}{...}
 {res}   103951     65290
{txt}{ralign 8:30} {...}
{c |}{...}
 {res}     7311      5094
{txt}{ralign 8:31} {...}
{c |}{...}
 {res}     5232      3127
{txt}{ralign 8:32} {...}
{c |}{...}
 {res}    57132     33796
{txt}{ralign 8:62} {...}
{c |}{...}
 {res}       43        35
{txt}{hline 9}{c BT}{hline 20}

{com}. egen totalg = total(granted)
{txt}
{com}. sum totalg

{txt}    Variable {c |}        Obs        Mean    Std. Dev.       Min        Max
{hline 13}{c +}{hline 57}
{space 6}totalg {c |}{res}         24      646339           0     646339     646339
{txt}
{com}. 
. 
. // Total number of patents in the world 1992-2000 by industry and country (top 10)
. // Drop duplicates in nace (2 digit) and country
. // Note: a patent is only counted ones in each nace (2 digit) and country
. use $tmp/finsample, clear
{txt}
{com}. gen nace = int(nace2_1) // 2-digit nace
{txt}
{com}. collapse (max) granted (min) y, by(docdb_family_id nace headq)
{txt}
{com}. keep if y>=1992 & y<=2000 // sample period
{txt}(2,756,280 observations deleted)

{com}. gen top10 = (headq=="US" | headq=="JP" | headq=="DE" | headq=="GB" | headq=="FR" ///
>         | headq=="IT" | headq=="CA" | headq=="MX" | headq=="BR" | headq=="ES") 
{txt}
{com}.         // 10 major economies in 2000 (nominal gdp)
. collapse (count) p = docdb (sum) g = granted, by(headq nace top10)
{txt}
{com}. keep if top10 == 1
{txt}(437 observations deleted)

{com}. drop top10 
{txt}
{com}. reshape wide p g, i(nace) j(headq) string
{txt}(note: j = BR CA DE ES FR GB IT JP MX US)

Data{col 36}long{col 43}->{col 48}wide
{hline 77}
Number of obs.                 {res}     204   {txt}->{res}      24
{txt}Number of variables            {res}       4   {txt}->{res}      21
{txt}j variable (10 values)            {res}headq   {txt}->   (dropped)
xij variables:
                                      {res}p   {txt}->   {res}pBR pCA ... pUS
                                      g   {txt}->   {res}gBR gCA ... gUS
{txt}{hline 77}

{com}. order nace pUS pJP pDE pGB pFR pIT pCA pMX pBR pES
{txt}
{com}. tabstat p??, by(nace) nototal

{txt}Summary statistics: mean
  by categories of: nace 

{ralign 8:nace} {...}
{c |}{...}
       pUS       pJP       pDE       pGB       pFR       pIT       pCA       pMX       pBR       pES
{hline 9}{c +}{hline 100}
{ralign 8:10} {...}
{c |}{...}
 {res}     2522      5267       284       248       304       235       111         5         .        14
{txt}{ralign 8:11} {...}
{c |}{...}
 {res}      170       330        60        31        38        12         .         .         .         .
{txt}{ralign 8:12} {...}
{c |}{...}
 {res}      253        43         7         9        17         9         3         .         .         1
{txt}{ralign 8:13} {...}
{c |}{...}
 {res}      877      2334       139        12        64        64        47         .         .         2
{txt}{ralign 8:14} {...}
{c |}{...}
 {res}      106       270        16        25        57        75        10         .         5         5
{txt}{ralign 8:15} {...}
{c |}{...}
 {res}      326       550       121        66        68       132        13         .         .         5
{txt}{ralign 8:16} {...}
{c |}{...}
 {res}       14       146        95         5         3         6        24         .         .         .
{txt}{ralign 8:17} {...}
{c |}{...}
 {res}      108      3526        15        22        59         7        79         .         4         .
{txt}{ralign 8:18} {...}
{c |}{...}
 {res}      198      1429        78        39        12        25        10         .         .         .
{txt}{ralign 8:19} {...}
{c |}{...}
 {res}      106       476        14        97       114         2       118         .         8         .
{txt}{ralign 8:20} {...}
{c |}{...}
 {res}    16813     88696      3128      2107      2248      1017      1245        88       125       103
{txt}{ralign 8:21} {...}
{c |}{...}
 {res}    22050      8344      3689      2922      2106      1294       906         .         .       605
{txt}{ralign 8:22} {...}
{c |}{...}
 {res}     3355     28953      1303      1236       706       624       323         1         6       190
{txt}{ralign 8:23} {...}
{c |}{...}
 {res}     1705     25684       468       559       406       301        21         2        32        32
{txt}{ralign 8:24} {...}
{c |}{...}
 {res}      791      7558       531       102       239        88       118        31       257        34
{txt}{ralign 8:25} {...}
{c |}{...}
 {res}     2086      6524      3803      1065      1135       627       195         4        16       122
{txt}{ralign 8:26} {...}
{c |}{...}
 {res}    60754    141047      9231      4556      7403      6266      5745         4        46       125
{txt}{ralign 8:27} {...}
{c |}{...}
 {res}     8508     48459      4102      1178      2705      1538       169         7        15       356
{txt}{ralign 8:28} {...}
{c |}{...}
 {res}    27480    185823     12442      3840      5284      3748      1067         7       130       473
{txt}{ralign 8:29} {...}
{c |}{...}
 {res}     8248     50626      6701      1021      2393      1177       453         .        45       121
{txt}{ralign 8:30} {...}
{c |}{...}
 {res}     1291      1523       773       358       415       252       189         .         .        46
{txt}{ralign 8:31} {...}
{c |}{...}
 {res}      988      1940       797       187       193       226        42         .         1       214
{txt}{ralign 8:32} {...}
{c |}{...}
 {res}    13287     28945      4095      2123      1443      1227       612         2        41       248
{txt}{ralign 8:62} {...}
{c |}{...}
 {res}       39         4         .         .         .         .         .         .         .         .
{txt}{hline 9}{c BT}{hline 100}

{com}. order nace gUS gJP gDE gGB gFR gIT gCA gMX gBR gES
{txt}
{com}. tabstat g??, by(nace) nototal

{txt}Summary statistics: mean
  by categories of: nace 

{ralign 8:nace} {...}
{c |}{...}
       gUS       gJP       gDE       gGB       gFR       gIT       gCA       gMX       gBR       gES
{hline 9}{c +}{hline 100}
{ralign 8:10} {...}
{c |}{...}
 {res}     2097      2410       149       132       239       189        60         0         .        13
{txt}{ralign 8:11} {...}
{c |}{...}
 {res}      138       156        40        18        35        12         .         .         .         .
{txt}{ralign 8:12} {...}
{c |}{...}
 {res}      168         9         7         2        12         9         3         .         .         1
{txt}{ralign 8:13} {...}
{c |}{...}
 {res}      716      1180        64         7        45        56        41         .         .         2
{txt}{ralign 8:14} {...}
{c |}{...}
 {res}       82       146         9        11        51        51         9         .         2         4
{txt}{ralign 8:15} {...}
{c |}{...}
 {res}      296       275        66        25        49       106         9         .         .         4
{txt}{ralign 8:16} {...}
{c |}{...}
 {res}       11        20        70         5         3         5        17         .         .         .
{txt}{ralign 8:17} {...}
{c |}{...}
 {res}       80       997        10        10        50         7        64         .         1         .
{txt}{ralign 8:18} {...}
{c |}{...}
 {res}      165       578        28        19         8        25         8         .         .         .
{txt}{ralign 8:19} {...}
{c |}{...}
 {res}       74       228        10        77       102         2        84         .         1         .
{txt}{ralign 8:20} {...}
{c |}{...}
 {res}    13429     31949      1944       977      1791       855       733         8        49        90
{txt}{ralign 8:21} {...}
{c |}{...}
 {res}    14069      3999      2175      1358      1613      1011       613         .         .       549
{txt}{ralign 8:22} {...}
{c |}{...}
 {res}     2784     11880       771       524       556       504       241         1         2       139
{txt}{ralign 8:23} {...}
{c |}{...}
 {res}     1402      8698       292       200       317       252        19         2         1        30
{txt}{ralign 8:24} {...}
{c |}{...}
 {res}      649      3015       348        57       203        71        77        26        36        26
{txt}{ralign 8:25} {...}
{c |}{...}
 {res}     1734      3614      2701       269       966       522       127         3         8       116
{txt}{ralign 8:26} {...}
{c |}{...}
 {res}    54894     53738      5544      2448      5868      5573      4741         3        17       116
{txt}{ralign 8:27} {...}
{c |}{...}
 {res}     7331     15726      2596       695      2303      1302       113         7         2       301
{txt}{ralign 8:28} {...}
{c |}{...}
 {res}    21867     78111      8058      1659      4473      2959       772         7        35       403
{txt}{ralign 8:29} {...}
{c |}{...}
 {res}     6738     23593      4372       429      1794      1016       119         .        26       103
{txt}{ralign 8:30} {...}
{c |}{...}
 {res}     1053       674       508       178       353       210       132         .         .        36
{txt}{ralign 8:31} {...}
{c |}{...}
 {res}      842       770       450        75       151       193        27         .         1       202
{txt}{ralign 8:32} {...}
{c |}{...}
 {res}    10798     13327      2652       928      1104       933       413         1        24       221
{txt}{ralign 8:62} {...}
{c |}{...}
 {res}       33         2         .         .         .         .         .         .         .         .
{txt}{hline 9}{c BT}{hline 100}

{com}. 
. 
. * -----------------------------------------------------------------------------
. * Appendix Table 10 - Final sample
. * Number of firms patenting by industry (and country)
. * -----------------------------------------------------------------------------
. // Total number of firms patenting in the world 1992-2000 by industry
. use $tmp/finsample, clear
{txt}
{com}. gen nace = int(nace2_1) // 2-digit nace
{txt}
{com}. keep if y>=1992 & y<=2000 // sample period
{txt}(2,816,106 observations deleted)

{com}. collapse (sum) granted, by(hrm nace)
{txt}
{com}. collapse (count) firms = hrm if granted > 0, by(nace)
{txt}
{com}. tabstat firms, by(nace) nototal

{txt}Summary for variables: firms
{col 6}by categories of: nace 

{ralign 8:nace} {...}
{c |}      mean
{hline 9}{c +}{hline 10}
{ralign 8:10} {...}
{c |}{...}
 {res}      487
{txt}{ralign 8:11} {...}
{c |}{...}
 {res}       43
{txt}{ralign 8:12} {...}
{c |}{...}
 {res}       27
{txt}{ralign 8:13} {...}
{c |}{...}
 {res}      154
{txt}{ralign 8:14} {...}
{c |}{...}
 {res}       97
{txt}{ralign 8:15} {...}
{c |}{...}
 {res}      125
{txt}{ralign 8:16} {...}
{c |}{...}
 {res}       46
{txt}{ralign 8:17} {...}
{c |}{...}
 {res}      121
{txt}{ralign 8:18} {...}
{c |}{...}
 {res}       85
{txt}{ralign 8:19} {...}
{c |}{...}
 {res}       97
{txt}{ralign 8:20} {...}
{c |}{...}
 {res}     2585
{txt}{ralign 8:21} {...}
{c |}{...}
 {res}     1673
{txt}{ralign 8:22} {...}
{c |}{...}
 {res}     1292
{txt}{ralign 8:23} {...}
{c |}{...}
 {res}      619
{txt}{ralign 8:24} {...}
{c |}{...}
 {res}      527
{txt}{ralign 8:25} {...}
{c |}{...}
 {res}     1159
{txt}{ralign 8:26} {...}
{c |}{...}
 {res}     4437
{txt}{ralign 8:27} {...}
{c |}{...}
 {res}     2276
{txt}{ralign 8:28} {...}
{c |}{...}
 {res}     8714
{txt}{ralign 8:29} {...}
{c |}{...}
 {res}     1514
{txt}{ralign 8:30} {...}
{c |}{...}
 {res}      708
{txt}{ralign 8:31} {...}
{c |}{...}
 {res}      467
{txt}{ralign 8:32} {...}
{c |}{...}
 {res}     3615
{txt}{ralign 8:62} {...}
{c |}{...}
 {res}        3
{txt}{hline 9}{c BT}{hline 10}

{com}. // Check total number of firms is same as in final sample
. egen totalf = total(firms)
{txt}
{com}. sum total 

{txt}    Variable {c |}        Obs        Mean    Std. Dev.       Min        Max
{hline 13}{c +}{hline 57}
{space 6}totalf {c |}{res}         24       30871           0      30871      30871
{txt}
{com}. 
. // Total number of firms patenting in the world 1992-2000 by industry and country
. use $tmp/finsample, clear
{txt}
{com}. gen nace = int(nace2_1) // 2-digit nace
{txt}
{com}. keep if y>=1992 & y<=2000 // sample period
{txt}(2,816,106 observations deleted)

{com}. gen top10 = (headq=="US" | headq=="JP" | headq=="DE" | headq=="GB" | headq=="FR" ///
>         | headq=="IT" | headq=="CA" | headq=="MX" | headq=="BR" | headq=="ES") 
{txt}
{com}.         // 10 major economies in 2000 (nominal gdp)
. collapse (sum) granted, by(hrm headq top10 nace)
{txt}
{com}. collapse (count) firms = hrm if granted > 0, by(headq top10 nace)
{txt}
{com}. keep if top10==1
{txt}(431 observations deleted)

{com}. drop top10 
{txt}
{com}. reshape wide firms, i(nace) j(headq) string
{txt}(note: j = BR CA DE ES FR GB IT JP MX US)

Data{col 36}long{col 43}->{col 48}wide
{hline 77}
Number of obs.                 {res}     203   {txt}->{res}      24
{txt}Number of variables            {res}       3   {txt}->{res}      11
{txt}j variable (10 values)            {res}headq   {txt}->   (dropped)
xij variables:
                                  {res}firms   {txt}->   {res}firmsBR firmsCA ... firmsUS
{txt}{hline 77}

{com}. order nace firmsUS firmsJP firmsDE firmsGB firmsFR firmsIT firmsCA firmsMX ///
>         firmsBR firmsES
{txt}
{com}. tabstat firms??, by(nace) nototal

{txt}Summary statistics: mean
  by categories of: nace 

{ralign 8:nace} {...}
{c |}{...}
   firmsUS   firmsJP   firmsDE   firmsGB   firmsFR   firmsIT   firmsCA   firmsMX   firmsBR   firmsES
{hline 9}{c +}{hline 100}
{ralign 8:10} {...}
{c |}{...}
 {res}      106       132        42        19        42        37         8         .         .         3
{txt}{ralign 8:11} {...}
{c |}{...}
 {res}       12         4         7         7         4         4         .         .         .         .
{txt}{ralign 8:12} {...}
{c |}{...}
 {res}        6         2         3         1         2         3         2         .         .         1
{txt}{ralign 8:13} {...}
{c |}{...}
 {res}       42        34        17         5        14        14         2         .         .         2
{txt}{ralign 8:14} {...}
{c |}{...}
 {res}       26        14         6         8         8        13         5         .         2         1
{txt}{ralign 8:15} {...}
{c |}{...}
 {res}       32         6        14         9        18        19         3         .         .         2
{txt}{ralign 8:16} {...}
{c |}{...}
 {res}        3         7        19         1         1         2         4         .         .         .
{txt}{ralign 8:17} {...}
{c |}{...}
 {res}       23        14         7         6        16         3        11         .         1         .
{txt}{ralign 8:18} {...}
{c |}{...}
 {res}       26        21        10         8         4         2         3         .         .         .
{txt}{ralign 8:19} {...}
{c |}{...}
 {res}       30        16         5         1         5         1        17         .         1         .
{txt}{ralign 8:20} {...}
{c |}{...}
 {res}      701       673       244       125       161       138        64         2        11        16
{txt}{ralign 8:21} {...}
{c |}{...}
 {res}      493       333       110        80       143       122        28         .         .        31
{txt}{ralign 8:22} {...}
{c |}{...}
 {res}      367       158       167        89        85       123        52         1         2        31
{txt}{ralign 8:23} {...}
{c |}{...}
 {res}      124       137        71        27        70        53        11         1         1         8
{txt}{ralign 8:24} {...}
{c |}{...}
 {res}      108       141        68        22        31        19        31         2         6         2
{txt}{ralign 8:25} {...}
{c |}{...}
 {res}      257       108       183        81       103       117        37         2         3        20
{txt}{ralign 8:26} {...}
{c |}{...}
 {res}     1496       802       439       301       351       233       128         3         4        22
{txt}{ralign 8:27} {...}
{c |}{...}
 {res}      620       309       319       112       213       231        55         3         2        49
{txt}{ralign 8:28} {...}
{c |}{...}
 {res}     2391      1422      1232       421       649       664       229         6        10        87
{txt}{ralign 8:29} {...}
{c |}{...}
 {res}      401       246       210       105       124       128        28         .         3        26
{txt}{ralign 8:30} {...}
{c |}{...}
 {res}      208        61        82        49        75        52        29         .         .         7
{txt}{ralign 8:31} {...}
{c |}{...}
 {res}      120        30        64        30        37        54        10         .         1        27
{txt}{ralign 8:32} {...}
{c |}{...}
 {res}     1295       417       402       193       279       234       117         1         7        41
{txt}{ralign 8:62} {...}
{c |}{...}
 {res}        2         1         .         .         .         .         .         .         .         .
{txt}{hline 9}{c BT}{hline 100}

{com}. 
. log close
      {txt}name:  {res}<unnamed>
       {txt}log:  {res}/Users/fcoell/Dropbox/PATSTAT/DATA/../logs/Appendix_Section_K.smcl
  {txt}log type:  {res}smcl
 {txt}closed on:  {res}14 Apr 2020, 11:56:30
{txt}{.-}
{smcl}
{txt}{sf}{ul off}